import { RouterModule } from '@angular/router';

import { PostComponent } from './postlist/post.component';
import { PostDetailMainComponent } from './post-detail-main/post-detail-main.component';
import { WritePostComponent } from './write-post/write-post.component';

export const postRoutes=[
  {
		path:'',
		redirectTo:'posts/page/1',
		pathMatch:'full'
	},
	{
		path:'posts/page/:page',
		component:PostComponent
	},
    { 
		path: 'post/postdetail/:postId', 
		component: PostDetailMainComponent 
	},
    { 
		path: 'user/write', 
		component: WritePostComponent 
	}
];